IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = object_id(N'[dbo].[DeletePedidoByIdCliente]') AND OBJECTPROPERTY(id, N'IsProcedure') = 1)
	DROP PROCEDURE [dbo].[DeletePedidoByIdCliente]
GO

CREATE PROCEDURE [dbo].[DeletePedidoByIdCliente]
(
	@IdCliente int
)
AS
BEGIN
	SET NOCOUNT ON

	DELETE FROM [Pedido]
	WHERE [IdCliente] = @IdCliente

	SET NOCOUNT OFF
END

GO
